package com.ygqh.baby.po;

import java.io.Serializable;
import java.util.Date;
import java.util.List;

import com.ygqh.baby.ao.DataStatus;

public class AdminUser implements Serializable{
    /**
	 * 
	 */
	private static final long serialVersionUID = -2012815791362436931L;

	private Long id;

    private String username;

    private String password;

    private Long supplierId;

    private String trueName;

    private DataStatus status;

    private Date lastLogintime;

    private Date createTime;

    private Date updateTime;

    private String updateBy;

    private String salt;
    
    private String createBy;

    
    
    private List<AdminPermission> menus;// 菜单
	
    private List<AdminPermission> permissions;// 权限
    
    private List<AdminRole> roles;
    
    
    
    public List<AdminRole> getRoles() {
		return roles;
	}

	public void setRoles(List<AdminRole> roles) {
		this.roles = roles;
	}
	
	public String getCreateBy() {
		return createBy;
	}

	public void setCreateBy(String createBy) {
		this.createBy = createBy;
	}

	public List<AdminPermission> getMenus() {
		return menus;
	}

	public void setMenus(List<AdminPermission> menus) {
		this.menus = menus;
	}

	public List<AdminPermission> getPermissions() {
		return permissions;
	}

	public void setPermissions(List<AdminPermission> permissions) {
		this.permissions = permissions;
	}

	public String getCredentialsSalt() {
		return username + salt;
	}
    
    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username == null ? null : username.trim();
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password == null ? null : password.trim();
    }

    public Long getSupplierId() {
        return supplierId;
    }

    public void setSupplierId(Long supplierId) {
        this.supplierId = supplierId;
    }

    public String getTrueName() {
        return trueName;
    }

    public void setTrueName(String trueName) {
        this.trueName = trueName == null ? null : trueName.trim();
    }


    public Date getLastLogintime() {
        return lastLogintime;
    }

    public void setLastLogintime(Date lastLogintime) {
        this.lastLogintime = lastLogintime;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public Date getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }

    public String getUpdateBy() {
        return updateBy;
    }

    public void setUpdateBy(String updateBy) {
        this.updateBy = updateBy == null ? null : updateBy.trim();
    }

    public String getSalt() {
        return salt;
    }

    public void setSalt(String salt) {
        this.salt = salt == null ? null : salt.trim();
    }

	public DataStatus getStatus() {
		return status;
	}

	public void setStatus(DataStatus status) {
		this.status = status;
	}
}